import { NavLink } from 'react-router-dom'

export default (Com: any) => {
	const token = localStorage.getItem('token');

	if(!token) {
		return <div>
			<h3>当前用户没有登录</h3>
			<NavLink to="/login">请登录</NavLink>
		</div>
	}

	return <Com></Com>
}